<template>
  <el-card class="app-container">
    <c-u-r-d-table :option="option" />
  </el-card>
</template>

<script>

import ColumnType from '@/framework/constant/ColumnType'
import ContentTypeEnum from '@/feature/system/infra/constants/ContentTypeEnum'
import { sysInfoApi } from '@/feature/system/infra/api/sysInfoApi'
import CURDTable from '@/framework/components/table/CURDTable'

export default {
  components: { CURDTable },
  data() {
    return {
      option: {
        requestApi: sysInfoApi,
        showSelection: false,
        columns: [
          {
            label: '标题',
            searchable: true,
            width: 300,
            required: true,
            span: 24,
            prop: 'title'
          },
          {
            label: '内容',
            required: true,
            span: 24,
            type: ColumnType.RICH_EDITOR,
            hiddenInTable: true,
            prop: 'content'
          },
          // {
          //   label: '链接地址',
          //   prop: 'link'
          // },
          // {
          //   label: '内容类型',
          //   prop: 'contentType',
          //   type: ColumnType.RADIO,
          //   options: ContentTypeEnum
          // },
          // {
          //   label: 'token',
          //   prop: 'token'
          // },
          {
            label: '创建时间',
            type: ColumnType.DATETIME,
            hiddenInForm: true,
            prop: 'gmtCreate'
          },
          {
            label: '修改时间',
            type: ColumnType.DATETIME,
            hiddenInForm: true,
            prop: 'gmtModified'
          }
        ]
      }
    }
  },
  methods: {}
}
</script>

